package insight.jsp.custom.taglib;

import java.io.IOException;
import java.io.InputStream;
import java.io.StringWriter;

import javax.servlet.jsp.JspException;
import javax.servlet.jsp.JspWriter;
import javax.servlet.jsp.tagext.TagSupport;

import org.apache.commons.io.IOUtils;

public class CustomerSelTagHandler extends TagSupport {
	private static final long serialVersionUID = 1L;
	private String incTiny;

	@Override
	public int doStartTag() throws JspException {
		try {
			JspWriter out = pageContext.getOut();
			InputStream in = this.getClass().getClassLoader()
					.getResourceAsStream("customersel.inc");
			StringWriter writer = new StringWriter();
			IOUtils.copy(in, writer, "UTF-8");
			String outStr = writer.toString();
			in.close();
			writer.close();
			out.println(outStr);
		} catch (IOException e) {
			e.printStackTrace();
		}
		return SKIP_BODY;
	}

	public String getIncTiny() {
		return incTiny;
	}

	public void setIncTiny(String incTiny) {
		this.incTiny = incTiny;
	}

}